Skip to content

Pass valid count pointer to LLVMGetModuleIdentifier #171

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Dec 23, 2018
Merged

Pass valid count pointer to LLVMGetModuleIdentifier #171

merged 2 commits into from
Dec 23, 2018

Conversation

matthewseaman
Copy link
Collaborator

Module.name was passing nil to arg 2 of LLVMGetModuleIdentifier, which appears to cause a seg fault every time it is called because it always tries to write the count to the pointer.

Fixed by using dummy count variable and passing it inout.
Added test assertions to Module link test.

@CodaFi
Copy link
Member

CodaFi commented Dec 23, 2018

Thanks!

@CodaFi CodaFi merged commit 98b95ab into llvm-swift:master Dec 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants